Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add datadog version tag configuration #16383

Merged
merged 6 commits into from
Apr 19, 2024
Merged

Add datadog version tag configuration #16383

merged 6 commits into from
Apr 19, 2024

Conversation

acrollet
Copy link
Contributor

@acrollet acrollet commented Apr 17, 2024

Summary

  • This work is behind a feature toggle (flipper): NO

This PR adds configuration for Datadog version tagging. This will support various quality of life improvements in datadog, and functionality like faulty deployment detection.

Dependencies

This relies on https://github.com/department-of-veterans-affairs/vsp-infra-application-manifests/pull/2807, but can be committed before it is.

What areas of the site does it impact?

  • datadog service configuration

@acrollet acrollet requested review from a team as code owners April 17, 2024 17:47
Copy link

github-actions bot commented Apr 17, 2024

1 Error
🚫 This PR changes 1146 LoC (not counting whitespace/newlines).

In order to ensure each PR receives the proper attention it deserves, those exceeding
500 will not be reviewed, nor will they be allowed to merge. Please break this PR up into
smaller ones.

If you have reason to believe that this PR should be granted an exception, please see the
Submitting pull requests for approval - FAQ.

File Summary

Files

  • .github/workflows/build.yml (+182/-5)

  • .github/workflows/code_checks.yml (+0/-121)

  • .github/workflows/deploy-template.yml (+98/-0)

  • .gitignore (+1/-0)

  • Dockerfile (+53/-96)

  • Gemfile (+1/-1)

  • Makefile (+1/-1)

  • app/controllers/application_controller.rb (+0/-1)

  • app/uploaders/uploader_virus_scan.rb (+4/-3)

  • bin/deps (+1/-0)

  • bin/fake_clamdscan (+0/-5)

  • bin/test (+1/-0)

  • bin/test-setup (+2/-0)

  • clamav_tmp/1e7e39bfccbd672ca2fd00ead324b391 (+1/-0)

  • clamav_tmp/a0960199b278fd7e95f4df40f56046cd (+1/-0)

  • clamav_tmp/fe1ade8b718b283067640956690ffba6 (+1/-0)

  • config/ca-trust/README.md (+5/-1)

  • config/ca-trust/fwdproxy.crt (+24/-0)

  • config/clamd.conf (+4/-2)

  • config/freshclam.conf (+1/-1)

  • config/initializers/clamav.rb (+18/-0)

  • config/initializers/clamscan.rb (+0/-5)

  • config/initializers/datadog.rb (+0/-4)

  • config/settings.yml (+3/-0)

  • docker-compose-clamav.yml (+10/-0)

  • docker-compose-deps.yml (+8/-1)

  • docker-compose.yml (+46/-34)

  • docs/setup/hybrid.md (+40/-1)

  • docs/setup/native.md (+41/-22)

  • docs/setup/running_docker.md (+21/-0)

  • docs/setup/running_natively.md (+19/-7)

  • import-va-certs.sh (+5/-2)

  • lib/clamav/commands/patch_scan_command.rb (+43/-0)

  • lib/clamav/patch_client.rb (+76/-0)

  • lib/common/file_helpers.rb (+17/-0)

  • lib/common/models/redis_store.rb (+2/-2)

  • lib/common/virus_scan.rb (+12/-4)

  • lib/shrine/plugins/validate_virus_free.rb (+5/-3)

  • spec/lib/shrine/plugins/validate_virus_free_spec.rb (+9/-23)

  • spec/models/persistent_attachments/dependency_claim_spec.rb (+5/-2)

  • spec/models/persistent_attachments/lgy_claim_spec.rb (+5/-2)

  • spec/models/persistent_attachments/pension_burial_spec.rb (+5/-2)

  • spec/requests/claim_documents_spec.rb (+2/-2)

  • spec/simplecov_helper.rb (+0/-1)

  • spec/spec_helper.rb (+0/-1)

  • spec/support/uploader_helpers.rb (+1/-7)

  • spec/uploaders/uploader_virus_scan_spec.rb (+3/-7)

    Note: We exclude files matching the following when considering PR size:

    *.csv, *.json, *.tsv, *.txt, Gemfile.lock, app/swagger, modules/mobile/docs, spec/fixtures/, spec/support/vcr_cassettes/, modules/mobile/spec/support/vcr_cassettes/, db/seeds, modules/vaos/app/docs, modules/meb_api/app/docs, modules/appeals_api/app/swagger/, *.bru
    

Big PRs are difficult to review, often become stale, and cause delays.

Generated by 🚫 Danger

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) was deleted but its reference still exists in CODEOWNERS. Please update the .github/CODEOWNERS file and delete the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) was deleted but its reference still exists in CODEOWNERS. Please update the .github/CODEOWNERS file and delete the entry for the Offending file:

@@ -81,6 +81,9 @@ jobs:
for env in ${envs[*]};
do
yq e -i '(.vets-api.image.tag) |= "${{ github.sha }}"' $env/values.yaml
yq e -i '(."vets-api".web.envSecrets[] | select(.name=="DD_VERSION").value) |= "${{ github.sha }}"' $env/values.yaml
yq e -i '(."vets-api".web.dbMigrate.envSecrets[] | select(.name=="DD_VERSION").value) |= "${{ github.sha }}"' $env/values.yaml
yq e -i '(."vets-api".worker.envSecrets[] | select(.name=="DD_VERSION").value) |= "${{ github.sha }}"' $env/values.yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the reason for having "vets-api" in quotes on these three lines?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was necessary because of the hyphen when I was testing locally, it would probably be good to add it to the existing line as well. Maybe it's due to a yq version difference?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

possibly. I bet both versions work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The jq manual says that keys with special chars should be quoted - I went ahead and added it to the first line for consistency.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok sounds good!

@@ -9,6 +9,7 @@
# Namespace our app
c.service = 'vets-api'
c.env = Settings.vsp_environment unless ENV['DD_ENV']
c.version = AppInfo::GIT_REVISION unless ENV['DD_VERSION']
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing we don't also need this on the master branch of this file as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will definitely need this in master as well.

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) was deleted but its reference still exists in CODEOWNERS. Please update the .github/CODEOWNERS file and delete the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) was deleted but its reference still exists in CODEOWNERS. Please update the .github/CODEOWNERS file and delete the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) was deleted but its reference still exists in CODEOWNERS. Please update the .github/CODEOWNERS file and delete the entry for the Offending file:

@va-vsp-bot
Copy link
Collaborator

Error: A file (or its parent directories) does not have a CODEOWNERS entry. Please update the .github/CODEOWNERS file and add the entry for the Offending file:

Copy link
Contributor

@rmtolmach rmtolmach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests passing. The ❌ failures are expected and can be ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants